//
// Created by HP on 2025/11/16.
//

#ifndef FLIGHTSERVER_TICKET_H
#define FLIGHTSERVER_TICKET_H
#include "Model.h"

class TypeOfTicket {
public:
    static std::string HIGHSPEEDTRAINFirstClass;
    static std::string HIGHSPEEDTRAINSecondClass;

    static std::string QUICKSPEEDTRAINFirstClass;
    static std::string QUICKSPEEDTRAINSecondClass;

    static std::string NORMALLQUICKTRAINSoftBed;
    static std::string NORMALLQUICKTRAINHardBed;
    static std::string NORMALLQUICKTRAINSoftSeat;
    static std::string NORMALLQUICKTRAINHardSeat;
    static std::string NORMALLQUICKTRAINNoSeat;

    static std::string PLANEFirstClass;
    static std::string PLANEEconomyClass;

    static std::string CARSeat;
};

class Ticket : public Model{
public:
    std::string id;
    std::string trainId;
    std::string name;
    std::string from;
    std::string to;
    int cnt;
    std::string price;
    std::string startTime;
    std::string endTime;
    std::string CreatedAt;
    std::string type;

    Ticket() ;

    void bind(const std::string& key, const std::string& value) ;

    bool save() ;
};


#endif //FLIGHTSERVER_TICKET_H
